/*
 * @desc:
 * @Author: 钟强
 * @Date: 2021-12-21 14:18:13
 * @LastEditors: 钟强
 * @LastEditTime: 2021-12-21 14:18:13
 */
import dayjs from 'dayjs'
export const dateFormat = (val, format = 'YYYY-MM-DD') => {
  if (isNaN(val)) {
    return val
  }
  val = parseInt(val)
  return dayjs(val).format(format)
}
